package system.queues;

import java.util.Queue;
import java.util.concurrent.ArrayBlockingQueue;

import system.wrap_filter.Standard;

public class AlertQueue {
	private Queue<Standard> alertBusffer;

	public AlertQueue() {
		alertBusffer = new ArrayBlockingQueue<Standard>(100000);
	}

	public boolean offer(Standard standard) {
		if (alertBusffer.size() < 100000) {
			alertBusffer.offer(standard);
			return true;
		} else {
			return false;
		}

	}

	public Standard poll() {
		return alertBusffer.poll();
	}

	public int getSize() {
		return alertBusffer.size();
	}
}
